<template>
  <div class="filter_item">
    <label class="filter_label" :class="{ colon: colon }">{{ label }}</label>
    <div class="filter_inner">
      <slot />
    </div>
  </div>
</template>

<script setup>
const props = defineProps({
  // 标签名
  label: {
    type: String,
    default: "",
  },
  // 是否显示冒号
  colon: {
    type: Boolean,
    default: true,
  },
});
</script>

<style lang="less" scoped>
.filter_item {
  display: flex;
  align-items: center;
  gap: 12px;
  .filter_label {
    font-size: 14px;
  }
  .colon::after {
    content: ":";
  }
  .filter_inner {
    flex: 1;
  }
}
</style>
